import request from './request.js';
let service = request.service;
let download = request.download;
export default {
    bZDrawingKeywords(data) {
        /**获取部件的图纸 */
        return service({
            url: `/adscm/operation/jqbzSettingsDraws/selectByKeyWord`,
            method: 'get',
            params: data
        })
    },
    bzDeleteDrawing(id){
       /**获取部件删除图纸 */
       return service({
           url: `/adscm/operation/jqbzSettingsDraws/delete/${id}`,
           method: 'get'
       })
    },
    addUpdatejqcsConfig(type,data) {
        /**机器出厂检验设置 insert-新增 update-修改 */
        return service({
            url: `/adscm/operation/jqcs/jqcsSetting/${type}`,
            method: 'post',
            data
        })
    },
    jqcsConfigList(data){
        /**机器出厂检验设置列表 */
        return service({
            url: `/adscm/operation/jqcs/jqcsSetting/selectAll`,
            method: 'post',
            data
        })
    },
    jqcsConfig(id) {
        /**机器出厂检验设置 */
        return service({
            url: `/adscm/operation/jqcs/jqcsSetting/selectById/${id}`,
            method: 'post'
        })
    },
     selectMachine() {
         /**获取设备所有类型*/
         return service({
             url: `/adscm/operation/jqbzSettings/selectJyDrawType`,
             method: 'get'
         })
     },
     jqcsSettingSjfileAll(){
         /**获取测试所有技术标准*/
         return service({
             url: `/adscm/operation/jqcs/jqcsSettingSjfile/selectAll`,
             method: 'get'
         })
     },
    selectSjfile(pid) {
         return service({
             url: `/adscm/operation/jqcs/jqcsSettingSjfile/selectBybid/${pid}`,
             method: 'get'
         })
    },
    addSjfile(data){
         /**机器出厂检验设置 */
         return service({
             url: `/adscm/operation/jqcs/jqcsSettingSjfile/insert`,
             method: 'post',
             data
         })
    },
    jqcsSettingDrawsAll(id, parentId) {
        /**获取测试所有图纸*/
        return service({
            url: `/adscm/operation/jqcs/jqcsSettingDraws/selectAll/${parentId}/${id}`,
            method: 'get'
        })
    },
    jqcsSettingDrawsSelect(pid) {
        /**根据id配置获取图纸*/
        return service({
            url: `/adscm/operation/jqcs/jqcsSettingDraws/selectBybid/${pid}`,
            method: 'get'
        })
    },
    addJqcsSettingDraws(data) {
         /**新增图纸配置*/
        return service({
            url: `/adscm/operation/jqcs/jqcsSettingDraws/insert`,
            method: 'post',
            data
        })
    },
    jqcsRemoveDraws(id) {
        /**移除图纸配置*/
        return service({
            url: `/adscm/operation/jqcs/jqcsSettingDraws/delete/${id}`,
            method: 'post'
        })
    },
    jqcsSettingsSopAll() {
            /**获取测试所有sop*/
            return service({
                url: `/adscm/operation/jqcs/jqcsSettingsSop/selectAll`,
                method: 'get'
            })
        },
    jqcsSettingsSopSelect(pid) {
        /**根据id配置获取sop*/
        return service({
            url: `/adscm/operation/jqcs/jqcsSettingsSop/selectBybid/${pid}`,
            method: 'get'
        })
    },
    addJqcsSettingsSop(data) {
        /**新增sop配置*/
        return service({
            url: `/adscm/operation/jqcs/jqcsSettingsSop/insert`,
            method: 'post',
            data
        })
    },
    jqcsSettingProcessList(pid) {
        /**测试过程信息列表*/
        return service({
            url: `/adscm/operation/jqcs/jqcsSettingProcess/selectByPid/${pid}`,
            method: 'post'
        })
    },
    addUpdateJqcsSettingProcess(type,data){
         /**新增测试过程信息 insert-新增 update-修改*/
         return service({
             url: `/adscm/operation/jqcs/jqcsSettingProcess/${type}`,
             method: 'post',
             data
         })
    },
    addUpdateJqfzSetting(type, data) {
         /**机器出厂检验设置 insert-新增 update-修改 */
         return service({
             url: `/adscm/operation/jqfz/jqfzSetting/${type}`,
             method: 'post',
             data
         })
     },
     jqfzSettingList() {
         /**机器出厂检验设置列表 */
         return service({
             url: `/adscm/operation/jqfz/jqfzSetting/selectAll`,
             method: 'post'
         })
     },
     jqfzSetting(id) {
         /**机器出厂检验设置 */
         return service({
             url: `/adscm/operation/jqfz/jqfzSetting/selectById/${id}`,
             method: 'post'
         })
     },
    jqfzSettingProcessList(pid) {
         /**测试发证信息列表*/
         return service({
             url: `/adscm/operation/jqfz/jqfzSettingProcess/selectByPid/${pid}`,
             method: 'post'
         })
     },
    addUpdateJqfzSettingProcess(type, data) {
        /**新增发证过程信息 insert-新增 update-修改*/
        return service({
            url: `/adscm/operation/jqfz/jqfzSettingProcess/${type}`,
            method: 'post',
            data
        })
    },
    addJqcsMachineTest(data) {
        /**下发任务 insert-新增 */
        return service({
            url: `/adscm/operation/jqcs/jqcsMachineTest/insert`,
            method: 'post',
            data
        })
    },
     updateJqcsMachineTest(data) {
         /**下发任务 update-修改 */
         return service({
             url: `/adscm/operation/jqcs/jqcsMachineTest/update`,
             method: 'post',
             data
         })
     },
    jqcsMachineTestList(data){
        /**下发任务列表*/
         return service({
             url: `/adscm/operation/jqcs/jqcsMachineTest/selectJqcsMachineTest`,
             method: 'post',
             data
         })
    },
      jqcsMachineTestTaskPerson() {
          /**下发任务列表- 任务负责人*/
          return service({
              url: `/adscm/operation/jqcs/jqcsMachineTest/selectTaskPerformPerson`,
              method: 'get',
          })
      },
      updateJqcsMachineTestProecss(data) {
          /**新增出厂检验过程*/
            return service({
                url: `/adscm/operation/jqcs/jqcsMachineTestProecss/update`,
                method: 'post',
                data
            })
      },
      jqcsMachineTestProecssList(pid) {
          /**出厂检验过程列表*/
          return service({
              url: `/adscm/operation/jqcs/jqcsMachineTestProecss/selectByPid/${pid}`,
              method: 'post',
          })
      },
      addJqfzIssueQs(data){
         /**发放合格证下发任务 insert-新增 */
         return service({
             url: `/adscm/operation/jqfz/jqfzIssueQs/insert`,
             method: 'post',
             data
         })
      },
      updateJqfzIssueQs(data) {
          /**发放合格证修改任务 insert-修改 */
          return service({
              url: `/adscm/operation/jqfz/jqfzIssueQs/update`,
              method: 'post',
              data
          })
      },
    jqfzIssueQsList(data) {
        /**发放合格证任务列表*/
        return service({
            url: `/adscm/operation/jqfz/jqfzIssueQs/selectJqfzIssueQs`,
            method: 'post',
            data
        })
    },
    jqfzIssueQsPerson(){
        /**发放合格证任务列表-任务负责人*/
        return service({
            url: `/adscm/operation/jqfz/jqfzIssueQs/selectTaskPerformPerson`,
            method: 'post',
        })
    },
    selectJqcheckRecoder(code) {
         /**发放合格证任务列表-机器所有装配信息*/
         return service({
             url: `/adscm/operation/jqfz/jqfzIssueQs/selectJqcheckRecoder/${code}`,
             method: 'post',
         })
    },
    jqfzIssueQsProecssList(pid) {
        /***发放合格证 - 过程信息列表*/
        return service({
            url: `/adscm/operation/jqfz/jqfzIssueQsProecss/selectByPid/${pid}`,
            method: 'post'
        })
    },
    updateJqfzIssueQsProecss(data) {
          /***发放合格证 - 添加过程信息*/
        return service({
            url: `/adscm/operation/jqfz/jqfzIssueQsProecss/update`,
            method: 'post',
            data
        })
    },
    jqfzSettingsDrawsAll(id, parentId) {
        /**发放合格证-所有图纸*/
        return service({
            url: `/adscm/operation/jqfz/jqfzSettingsDraws/selectAll/${parentId}/${id}`,
            method: 'post'
        })
    },
   jqfzSettingsDrawsSelect(pid) {
        /**根据pid查询发放合格证所配置图纸*/
        return service({
            url: `/adscm/operation/jqfz/jqfzSettingsDraws/selectBybid/${pid}`,
            method: 'post'
        })
    },
    addJqfzSettingsDraws(data) {
        /**新增pid发放合格证所配置图纸*/
        return service({
            url: `/adscm/operation/jqfz/jqfzSettingsDraws/insert`,
            method: 'post',
            data
        })
    },
    jqfzRemoveDraws(id) {
        /**删除发放合格证所配置图纸*/
        return service({
            url: `/adscm/operation/jqfz/jqfzSettingsDraws/delete/${id}`,
            method: 'post'
        })
    },
    jqfzSettingSopAll() {
        /**发放合格证所有SOP*/
        return service({
            url: `/adscm/operation/jqfz/jqfzSettingSop/selectAll`,
            method: 'post'
        })
    },
    jqfzSettingSopSelect(pid) {
        /**根据pid查询发放合格证所配置sop*/
        return service({
            url: `/adscm/operation/jqfz/jqfzSettingSop/selectBybid/${pid}`,
            method: 'post'
        })
    },
    addJqfzSettingSop(data) {
        /**新增pid查询发放合格证所配置sop*/
        return service({
            url: `/adscm/operation/jqfz/jqfzSettingSop/insert`,
            method: 'post',
            data
        })
    },
   jqfzSettingTechsAll() {
        /**发放合格证所有技术标准*/
        return service({
            url: `/adscm/operation/jqfz/jqfzSettingTechs/selectAll`,
            method: 'post'
        })
    },
    jqfzSettingTechsSelect(pid) {
        /**根据pid查询发放合格证所配置技术标准*/
        return service({
            url: `/adscm/operation/jqfz/jqfzSettingTechs/selectBybid/${pid}`,
            method: 'post'
        })
    },
    addJqfzSettingTechs(data) {
        /**新增pid查询发放合格证所配置技术标准*/
        return service({
            url: `/adscm/operation/jqfz/jqfzSettingTechs/insert`,
            method: 'post',
            data
        })
    },

    addUpdateJqdbSettings(type, data) {
        /**机器打包设置 insert-新增 update-修改 */
        return service({
            url: `/adscm/operation/jqdb/jqdbSettings/${type}`,
            method: 'post',
            data
        })
    },
    jqdbSettingsAll() {
        /**机器打包设置列表 */
        return service({
            url: `/adscm/operation/jqdb/jqdbSettings/selectAll`,
            method: 'post'
        })
    },
    jqdbSettings(id) {
        /**机器打包设置 */
        return service({
            url: `/adscm/operation/jqdb/jqdbSettings/selectById/${id}`,
            method: 'post'
        })
    },
    jqdbSettingProecssList(pid) {
        /**打包过程信息列表*/
        return service({
            url: `/adscm/operation/jqdb/jqdbSettingProecss/selectByPid/${pid}`,
            method: 'post'
        })
    },
    addUpdateJqdbSettingProecss(type, data) {
        /**新增打包过程信息 insert-新增 update-修改*/
        return service({
            url: `/adscm/operation/jqdb/jqdbSettingProecss/${type}`,
            method: 'post',
            data
        })
    },
    jqdbSettingsDrawsAll(id, parentId) {
        /**打包过程信息所有图纸*/
        return service({
            url: `/adscm/operation/jqdb/jqdbSettingsDraws/selectAll/${parentId}/${id}`,
            method: 'post'
        })
    },
    jqdbSettingsDrawsSelect(pid) {
        /**根据pid查询打包过程信息所配置图纸*/
        return service({
            url: `/adscm/operation/jqdb/jqdbSettingsDraws/selectBybid/${pid}`,
            method: 'post'
        })
    },
    addJqdbSettingsDraws(data) {
        /**新增pid查询打包过程信息所配置图纸*/
        return service({
            url: `/adscm/operation/jqdb/jqdbSettingsDraws/insert`,
            method: 'post',
            data
        })
    },
    jqdbRemoveDraws(id) {
         /**删除打包过程信息所配置图纸*/
         return service({
             url: `/adscm/operation/jqdb/jqdbSettingsDraws/delete/${id}`,
             method: 'post'
         })
     },
    jqdbSettingsSopAll() {
        /**打包过程信息所有SOP*/
        return service({
            url: `/adscm/operation/jqdb/jqdbSettingsSop/selectAll`,
            method: 'post'
        })
    },
    jqdbSettingsSopSelect(pid) {
        /**根据pid查询打包过程信息所配置sop*/
        return service({
            url: `/adscm/operation/jqdb/jqdbSettingsSop/selectBybid/${pid}`,
            method: 'post'
        })
    },
    addJqdbSettingsSop(data) {
        /**新增pid查询打包过程信息所配置sop*/
        return service({
            url: `/adscm/operation/jqdb/jqdbSettingsSop/insert`,
            method: 'post',
            data
        })
    },
    jqdbSettingTechsAll() {
        /**打包过程信息所有技术标准*/
        return service({
            url: `/adscm/operation/jqdb/jqdbSettingTechs/selectAll`,
            method: 'post'
        })
    },
    jqdbSettingTechsSelect(pid) {
        /**根据pid查询打包过程信息所配置技术标准*/
        return service({
            url: `/adscm/operation/jqdb/jqdbSettingTechs/selectBybid/${pid}`,
            method: 'post'
        })
    },
    addJqdbSettingTechs(data) {
        /**新增pid查询打包过程信息所配置技术标准*/
        return service({
            url: `/adscm/operation/jqdb/jqdbSettingTechs/insert`,
            method: 'post',
            data
        })
    },
    jqdbSettingsInputAll(id){
        /**打包过程- 获取所有物料*/
        return service({
            url: `/adscm/operation/jqdb/jqdbSettingsInput/selectAll/${id}`,
            method: 'post'
        })
    },
    jqdbSettingsInputList(pid) {
        /**根据pid查询打包过程已领物料*/
        return service({
            url: `/adscm/operation/jqdb/jqdbSettingsInput/selectByPid/${pid}`,
            method: 'post'
        })
    },
    deleteJqdbSettingsInput(id) {
         /**根据pid查询打包过程删除已领物料*/
         return service({
             url: `/adscm/operation/jqdb/jqdbSettingsInput/delete/${id}`,
             method: 'post'
         })
    },
    insertJqdbSettingsInput(data){
        /**根据pid查询打包过程-领取物料*/
        return service({
            url: `/adscm/operation/jqdb/jqdbSettingsInput/insert`,
            method: 'post',
            data
        })
    },
    addJqdbMachinepacking(data) {
        /**发放合格证下发任务 insert-新增 */
        return service({
            url: `/adscm/operation/jqdbMachinepacking/insert`,
            method: 'post',
            data
        })
    },
    updateJqdbMachinepacking(data) {
        /**发放打包任务 update-修改 */
        return service({
            url: `/adscm/operation/jqdbMachinepacking/update`,
            method: 'post',
            data
        })
    },
    jqdbMachinepackingList(data) {
        /**打包任务列表*/
        return service({
            url: `/adscm/operation/jqdbMachinepacking/selectJqdbMachinepacking`,
            method: 'post',
            data
        })
    },
    jqdbMachinepackingPerson() {
        /**发放打包任务列表-任务负责人*/
        return service({
            url: `/adscm/operation/jqdbMachinepacking/selectTaskPerformPerson`,
            method: 'post',
        })
    },
    jqdbMachinepackingProcessList(pid) {
         /**打包任务过程信息*/
         return service({
             url: `/adscm/operation/jqdb/jqdbMachinepackingProcess/selectByPid/${pid}`,
             method: 'post',
         })
    },
    updateJqdbMachinepackingProcess(data){
        /**打包任务过程信息修改*/
        return service({
            url: `/adscm/operation/jqdb/jqdbMachinepackingProcess/update`,
            method: 'post',
            data
        })
    },
    jqdbMaterialList(tid) {
         return service({
             url: `/adscm/operation/jqdb/jqdbMaterial/selectByTid/${tid}`,
             method: 'post',
         })
    },
    selectJqdbMaterialList(tid) {
         return service({
             url: `/adscm/operation/jqdb/jqdbMaterialList/selectByTid/${tid}`,
             method: 'post',
         })
    },
    jqdbMaterialListStore(id) {
         return service({
             url: `/adscm/operation/jqdb/jqdbMaterialList/queryMaterial/${id}`,
             method: 'post',
         })
    },
    addJqdbMaterialListStore(data) {
        /**打包任务-获取已选择库存中的原料*/
        return service({
            url: `/adscm/operation/jqdb/jqdbMaterialList/insert`,
            method: 'post',
            data
        })
    },
 deleteJqdbMaterial(id) {
     /**打包任务-删除物料 */
     return service({
         url: `/adscm/operation/jqdb/jqdbMaterialList/delete/${id}`,
         method: 'post'
     })
 },
 jqdbMaterialListCheckList(pid) {
     /**获取物料检测信息 */
     return service({
         url: `/adscm/operation/jqdb/jqdbMaterialListCheck/selectByPid/${pid}`,
         method: 'post'
     })
 },
 updateJqdbMaterialCheck(data) {
     /**获取物料检测信息 */
     return service({
         url: `/adscm/operation/jqdb/jqdbMaterialListCheck/update`,
         method: 'post',
         data
     })
 },
 jqfzIssueQsJQCs(code) {
     /**获取机器检测记录 */
     return service({
         url: `/adscm/operation/jqfz/jqfzIssueQs/selectJqcs/${code}`,
         method: 'post'
     })
 },
  jqfzIssueQsJQZz(code) {
      /**获取总装记录 */
      return service({
          url: `/adscm/operation/jqfz/jqfzIssueQs/selectJqzz/${code}`,
          method: 'post'
      })
  },
   jqfzIssueQsJQBz(code) {
       /**获取部装记录 */
       return service({
           url: `/adscm/operation/jqfz/jqfzIssueQs/selectJqbz/${code}`,
           method: 'post'
       })
   },
   unqualifiedMaterialTaskList(type){
       /**获取不合格原料列表 type: selectUnDeal-待办 selectDeal-已办 */
         return service({
             url: `/adscm/operation/jqylMaterialdetail/${type}`,
             method: 'post'
         })
   },
   updateUnqualified(data){
       /**修改待办不合格原料列表 */
     return service({
         url: `/adscm/operation/jqylMaterialdetail/updateUnqualified`,
         method: 'post',
         data
     })
   },
   jointHearingList(pid) {
       /**会审记录列表 */
        return service({
            url: `/adscm/operation/jqylMaterialdetailApprove/selectByPid/${pid}`,
            method: 'post'
        })
   },
    updateJointHearingList(data) {
        /**新增会审记录 */
       return service({
           url: `/adscm/operation/jqylMaterialdetailApprove/update`,
           method: 'post',
           data
       })
    },
    allOldProcedureList(){
        /**获取机器测试所有工序 */
        return service({
            url: `/adscm/operation/jqcs/jqcsSetting/select`,
            method: 'post'
        })
    },
    allFzProcedureList(){
        /**获取机器发证所有工序 */
        return service({
            url: `/adscm/operation/jqfz/jqfzSetting/selectAll`,
            method: 'post'
        })
    },
    allDbProcedureList() {
        /**获取机器发证所有工序 */
        return service({
            url: `/adscm/operation/jqdb/jqdbSettings/selectAll`,
            method: 'post'
        })
    },
    getCheckRecoder(code) {
        /**获取检验记录 */
        return service({
            url: `/adscm/operation/jqfz/jqfzIssueQs/selectJqcheckRecoder/${code}`,
            method: 'get'
        })
    }
}
